package com.yjd.comm.app.service;

import com.yjd.comm.base.enums.DbWREnums;
import com.yjd.comm.base.service.IBaseService;
import com.yjd.comm.app.model.PushRecordModel;

import java.util.Map;

/**
 * <b>description</b>：推送消息记录业务接口<br>
 * <b>time</b>：2017-08-11 17:30:25 <br>
 * <b>author</b>：  yangchangyan@yijiedai.com
 */
public interface IPushRecordService extends IBaseService {
	/**
	 * 插入
	 * 
	 * @param model
	 * @return
	 * @throws Exception
	 */
	public PushRecordModel insert(PushRecordModel model) throws Exception;

	/**
	 * 更新,大于等于1表示成功，其他失败
	 * 
	 * @param model
	 * @return
	 * @throws Exception
	 */
	public int update(PushRecordModel model) throws Exception;

	/**
	 * 根据map更新数据
	 *
	 * @param paramMap
	 * @param write 是否是操作主库
	 * @return
	 * @throws Exception
	 */
	public int updateByMap(Map paramMap, DbWREnums write) throws Exception;

	/**
	 * 根据id删除,大于等于1表示成功，其他失败
	 * 
	 * @param id
	 * @return
	 * @throws Exception
	 */
	public int delete(long id) throws Exception;

}
